<template>
    <div>
        <el-dialog 
            title="流程信息" 
            :visible.sync="isShow" 
            @close="closeDialog"
            :close-on-click-modal="false"  
        >
            <el-steps :active="currentState" align-center>
                <el-step title="未提交" description="已保存，提交后进入部门审核阶段"></el-step>
                <el-step title="部门经理审核" description="已提交，部门审核同意进入总经理审核阶段"></el-step>
                <el-step title="总经理审核" description="同意则订单完成，驳回则返回部门经理审核阶段"></el-step>
                <el-step title="已完成" description="订单申请成功"></el-step>
            </el-steps>
        </el-dialog>
    </div>
</template>

<script>
export default {
    name:'FlowInfo',
    props:{
        isShow: {
            type: Boolean,
            default: false
        },
        currentState: {
            type: Number,
            default: 0
        }
    },
    methods:{
        // 关闭弹窗，通过.sync机制同步父组件状态
        closeDialog(){
            this.$emit('update:isShow', false);
        }
    }
}
</script>

<style>
</style>
